{smcl}
{com}{sf}{ul off}{txt}{.-}
      name:  {res}<unnamed>
       {txt}log:  {res}C:\research\works\주제40_집_이민자_외국인지원\data\code.smcl
  {txt}log type:  {res}smcl
 {txt}opened on:  {res} 3 May 2025, 21:48:16

{com}. tsset id year
{res}{txt}{col 8}panel variable:  {res}id (unbalanced)
{txt}{col 9}time variable:  {res}{col 25}year, 2005 to 2022, but with gaps
{txt}{col 17}delta:  {res}1 unit

{com}. xtreg foreigner_right i.immigration##i.homeownership ln_income education sex age marriage capital religion ideology, re
{res}
{txt}Random-effects GLS regression                   Number of obs     = {res}     4,446
{txt}Group variable: {res}id                              {txt}Number of groups  = {res}     3,048

{txt}R-sq:                                           Obs per group:
     within  = {res}0.0075                                         {txt}min = {res}         1
{txt}     between = {res}0.0608                                         {txt}avg = {res}       1.5
{txt}     overall = {res}0.0501                                         {txt}max = {res}         2

                                                {txt}Wald chi2({res}11{txt})     =  {res}   221.08
{txt}corr(u_i, X)   = {res}0{txt} (assumed)                    Prob > chi2       =     {res}0.0000

{txt}{hline 26}{c TT}{hline 11}{hline 11}{hline 9}{hline 8}{hline 13}{hline 12}
{col 1}          foreigner_right{col 27}{c |}      Coef.{col 39}   Std. Err.{col 51}      z{col 59}   P>|z|{col 67}     [95% Con{col 80}f. Interval]
{hline 26}{c +}{hline 11}{hline 11}{hline 9}{hline 8}{hline 13}{hline 12}
{space 12}1.immigration {c |}{col 27}{res}{space 2} 1.831078{col 39}{space 2} .1915528{col 50}{space 1}    9.56{col 59}{space 3}0.000{col 67}{space 4} 1.455642{col 80}{space 3} 2.206515
{txt}{space 10}1.homeownership {c |}{col 27}{res}{space 2}-.0951903{col 39}{space 2} .0268592{col 50}{space 1}   -3.54{col 59}{space 3}0.000{col 67}{space 4}-.1478333{col 80}{space 3}-.0425473
{txt}{space 25} {c |}
immigration#homeownership {c |}
{space 21}1 1  {c |}{col 27}{res}{space 2}-2.335977{col 39}{space 2} .2518525{col 50}{space 1}   -9.28{col 59}{space 3}0.000{col 67}{space 4}-2.829599{col 80}{space 3}-1.842355
{txt}{space 25} {c |}
{space 16}ln_income {c |}{col 27}{res}{space 2}  -.05613{col 39}{space 2} .0219937{col 50}{space 1}   -2.55{col 59}{space 3}0.011{col 67}{space 4}-.0992367{col 80}{space 3}-.0130232
{txt}{space 16}education {c |}{col 27}{res}{space 2} .0512666{col 39}{space 2} .0149779{col 50}{space 1}    3.42{col 59}{space 3}0.001{col 67}{space 4} .0219105{col 80}{space 3} .0806228
{txt}{space 22}sex {c |}{col 27}{res}{space 2}-.0473669{col 39}{space 2} .0254708{col 50}{space 1}   -1.86{col 59}{space 3}0.063{col 67}{space 4}-.0972888{col 80}{space 3}  .002555
{txt}{space 22}age {c |}{col 27}{res}{space 2}-.0363309{col 39}{space 2} .0117392{col 50}{space 1}   -3.09{col 59}{space 3}0.002{col 67}{space 4}-.0593394{col 80}{space 3}-.0133224
{txt}{space 17}marriage {c |}{col 27}{res}{space 2} .0752064{col 39}{space 2} .0300383{col 50}{space 1}    2.50{col 59}{space 3}0.012{col 67}{space 4} .0163324{col 80}{space 3} .1340804
{txt}{space 18}capital {c |}{col 27}{res}{space 2} .1066784{col 39}{space 2} .0250774{col 50}{space 1}    4.25{col 59}{space 3}0.000{col 67}{space 4} .0575276{col 80}{space 3} .1558292
{txt}{space 17}religion {c |}{col 27}{res}{space 2}-.0227819{col 39}{space 2} .0244917{col 50}{space 1}   -0.93{col 59}{space 3}0.352{col 67}{space 4}-.0707849{col 80}{space 3}  .025221
{txt}{space 17}ideology {c |}{col 27}{res}{space 2}    -.016{col 39}{space 2} .0131443{col 50}{space 1}   -1.22{col 59}{space 3}0.224{col 67}{space 4}-.0417624{col 80}{space 3} .0097624
{txt}{space 20}_cons {c |}{col 27}{res}{space 2} 3.408917{col 39}{space 2} .1997747{col 50}{space 1}   17.06{col 59}{space 3}0.000{col 67}{space 4} 3.017365{col 80}{space 3} 3.800468
{txt}{hline 26}{c +}{hline 11}{hline 11}{hline 9}{hline 8}{hline 13}{hline 12}
                  sigma_u {c |} {res} .26569543
                  {txt}sigma_e {c |} {res} .73030412
                      {txt}rho {c |} {res} .11688955{txt}   (fraction of variance due to u_i)
{hline 26}{c BT}{hline 64}

{com}. 
. 
. 
. margins immigration, at(homeownership =(0(1)1))
{res}
{txt}Predictive margins{col 49}Number of obs{col 67}= {res}     4,446
{txt}Model VCE{col 14}: {res}Conventional

{txt}{p2colset 1 14 16 2}{...}
{p2col:Expression}:{space 1}{res:Linear prediction, predict()}{p_end}
{p2colreset}{...}

{txt}{p2colset 1 14 16 2}{...}
{p2col:1._at}:{space 1}{res:{txt:homeownership}{space 3}{txt:=} {space 10}0}{p_end}
{p2colreset}{...}

{txt}{p2colset 1 14 16 2}{...}
{p2col:2._at}:{space 1}{res:{txt:homeownership}{space 3}{txt:=} {space 10}1}{p_end}
{p2colreset}{...}

{res}{txt}{hline 16}{c TT}{hline 11}{hline 11}{hline 9}{hline 8}{hline 13}{hline 12}
{col 17}{c |}{col 29} Delta-method
{col 17}{c |}     Margin{col 29}   Std. Err.{col 41}      z{col 49}   P>|z|{col 57}     [95% Con{col 70}f. Interval]
{hline 16}{c +}{hline 11}{hline 11}{hline 9}{hline 8}{hline 13}{hline 12}
_at#immigration {c |}
{space 11}1 0  {c |}{col 17}{res}{space 2} 2.954096{col 29}{space 2} .0218505{col 40}{space 1}  135.20{col 49}{space 3}0.000{col 57}{space 4}  2.91127{col 70}{space 3} 2.996922
{txt}{space 11}1 1  {c |}{col 17}{res}{space 2} 4.785174{col 29}{space 2} .1905173{col 40}{space 1}   25.12{col 49}{space 3}0.000{col 57}{space 4} 4.411767{col 70}{space 3} 5.158581
{txt}{space 11}2 0  {c |}{col 17}{res}{space 2} 2.858906{col 29}{space 2} .0149224{col 40}{space 1}  191.58{col 49}{space 3}0.000{col 57}{space 4} 2.829658{col 70}{space 3} 2.888153
{txt}{space 11}2 1  {c |}{col 17}{res}{space 2} 2.354007{col 29}{space 2} .1648534{col 40}{space 1}   14.28{col 49}{space 3}0.000{col 57}{space 4}   2.0309{col 70}{space 3} 2.677114
{txt}{hline 16}{c BT}{hline 11}{hline 11}{hline 9}{hline 8}{hline 13}{hline 12}
{res}
{com}. 
. marginsplot

{text}{p 2 6 2}Variables that uniquely identify margins: homeownership immigration{p_end}
{res}
{com}. 
. 
. 
. xtreg foreigner_right i.immigration##c.ln_house_price ln_income education sex age marriage capital religion ideology, re
{res}
{txt}Random-effects GLS regression                   Number of obs     = {res}     4,183
{txt}Group variable: {res}id                              {txt}Number of groups  = {res}     2,900

{txt}R-sq:                                           Obs per group:
     within  = {res}0.0186                                         {txt}min = {res}         1
{txt}     between = {res}0.0736                                         {txt}avg = {res}       1.4
{txt}     overall = {res}0.0606                                         {txt}max = {res}         2

                                                {txt}Wald chi2({res}11{txt})     =  {res}   257.50
{txt}corr(u_i, X)   = {res}0{txt} (assumed)                    Prob > chi2       =     {res}0.0000

{txt}{hline 29}{c TT}{hline 11}{hline 11}{hline 9}{hline 8}{hline 13}{hline 12}
{col 1}             foreigner_right{col 30}{c |}      Coef.{col 42}   Std. Err.{col 54}      z{col 62}   P>|z|{col 70}     [95% Con{col 83}f. Interval]
{hline 29}{c +}{hline 11}{hline 11}{hline 9}{hline 8}{hline 13}{hline 12}
{space 15}1.immigration {c |}{col 30}{res}{space 2} 8.445262{col 42}{space 2} .8235727{col 53}{space 1}   10.25{col 62}{space 3}0.000{col 70}{space 4} 6.831089{col 83}{space 3} 10.05943
{txt}{space 14}ln_house_price {c |}{col 30}{res}{space 2}-.0643493{col 42}{space 2}  .009702{col 53}{space 1}   -6.63{col 62}{space 3}0.000{col 70}{space 4}-.0833648{col 83}{space 3}-.0453337
{txt}{space 28} {c |}
immigration#c.ln_house_price {c |}
{space 26}1  {c |}{col 30}{res}{space 2}-.9313016{col 42}{space 2}  .092457{col 53}{space 1}  -10.07{col 62}{space 3}0.000{col 70}{space 4}-1.112514{col 83}{space 3}-.7500892
{txt}{space 28} {c |}
{space 19}ln_income {c |}{col 30}{res}{space 2}-.0217264{col 42}{space 2}  .023314{col 53}{space 1}   -0.93{col 62}{space 3}0.351{col 70}{space 4} -.067421{col 83}{space 3} .0239682
{txt}{space 19}education {c |}{col 30}{res}{space 2} .0699021{col 42}{space 2} .0156285{col 53}{space 1}    4.47{col 62}{space 3}0.000{col 70}{space 4} .0392708{col 83}{space 3} .1005334
{txt}{space 25}sex {c |}{col 30}{res}{space 2}-.0298405{col 42}{space 2} .0260664{col 53}{space 1}   -1.14{col 62}{space 3}0.252{col 70}{space 4}-.0809298{col 83}{space 3} .0212488
{txt}{space 25}age {c |}{col 30}{res}{space 2}-.0284669{col 42}{space 2} .0121087{col 53}{space 1}   -2.35{col 62}{space 3}0.019{col 70}{space 4}-.0521995{col 83}{space 3}-.0047343
{txt}{space 20}marriage {c |}{col 30}{res}{space 2}  .094266{col 42}{space 2} .0310683{col 53}{space 1}    3.03{col 62}{space 3}0.002{col 70}{space 4} .0333733{col 83}{space 3} .1551587
{txt}{space 21}capital {c |}{col 30}{res}{space 2} .1381794{col 42}{space 2}  .025717{col 53}{space 1}    5.37{col 62}{space 3}0.000{col 70}{space 4}  .087775{col 83}{space 3} .1885839
{txt}{space 20}religion {c |}{col 30}{res}{space 2} -.018409{col 42}{space 2} .0250552{col 53}{space 1}   -0.73{col 62}{space 3}0.462{col 70}{space 4}-.0675162{col 83}{space 3} .0306982
{txt}{space 20}ideology {c |}{col 30}{res}{space 2}-.0132775{col 42}{space 2} .0134565{col 53}{space 1}   -0.99{col 62}{space 3}0.324{col 70}{space 4}-.0396518{col 83}{space 3} .0130968
{txt}{space 23}_cons {c |}{col 30}{res}{space 2} 3.533261{col 42}{space 2} .2057063{col 53}{space 1}   17.18{col 62}{space 3}0.000{col 70}{space 4} 3.130084{col 83}{space 3} 3.936438
{txt}{hline 29}{c +}{hline 11}{hline 11}{hline 9}{hline 8}{hline 13}{hline 12}
                     sigma_u {c |} {res}  .2680787
                     {txt}sigma_e {c |} {res} .72442792
                         {txt}rho {c |} {res} .12044707{txt}   (fraction of variance due to u_i)
{hline 29}{c BT}{hline 64}

{com}. 
. 
. 
. margins immigration, at(ln_house_price=(4(1)13))
{res}
{txt}Predictive margins{col 49}Number of obs{col 67}= {res}     4,183
{txt}Model VCE{col 14}: {res}Conventional

{txt}{p2colset 1 14 16 2}{...}
{p2col:Expression}:{space 1}{res:Linear prediction, predict()}{p_end}
{p2colreset}{...}

{txt}{p2colset 1 14 16 2}{...}
{p2col:1._at}:{space 1}{res:{txt:ln_house_p~e}{space 4}{txt:=} {space 10}4}{p_end}
{p2colreset}{...}

{txt}{p2colset 1 14 16 2}{...}
{p2col:2._at}:{space 1}{res:{txt:ln_house_p~e}{space 4}{txt:=} {space 10}5}{p_end}
{p2colreset}{...}

{txt}{p2colset 1 14 16 2}{...}
{p2col:3._at}:{space 1}{res:{txt:ln_house_p~e}{space 4}{txt:=} {space 10}6}{p_end}
{p2colreset}{...}

{txt}{p2colset 1 14 16 2}{...}
{p2col:4._at}:{space 1}{res:{txt:ln_house_p~e}{space 4}{txt:=} {space 10}7}{p_end}
{p2colreset}{...}

{txt}{p2colset 1 14 16 2}{...}
{p2col:5._at}:{space 1}{res:{txt:ln_house_p~e}{space 4}{txt:=} {space 10}8}{p_end}
{p2colreset}{...}

{txt}{p2colset 1 14 16 2}{...}
{p2col:6._at}:{space 1}{res:{txt:ln_house_p~e}{space 4}{txt:=} {space 10}9}{p_end}
{p2colreset}{...}

{txt}{p2colset 1 14 16 2}{...}
{p2col:7._at}:{space 1}{res:{txt:ln_house_p~e}{space 4}{txt:=} {space 9}10}{p_end}
{p2colreset}{...}

{txt}{p2colset 1 14 16 2}{...}
{p2col:8._at}:{space 1}{res:{txt:ln_house_p~e}{space 4}{txt:=} {space 9}11}{p_end}
{p2colreset}{...}

{txt}{p2colset 1 14 16 2}{...}
{p2col:9._at}:{space 1}{res:{txt:ln_house_p~e}{space 4}{txt:=} {space 9}12}{p_end}
{p2colreset}{...}

{txt}{p2colset 1 14 16 2}{...}
{p2col:10._at}:{space 1}{res:{txt:ln_house_p~e}{space 4}{txt:=} {space 9}13}{p_end}
{p2colreset}{...}

{res}{txt}{hline 16}{c TT}{hline 11}{hline 11}{hline 9}{hline 8}{hline 13}{hline 12}
{col 17}{c |}{col 29} Delta-method
{col 17}{c |}     Margin{col 29}   Std. Err.{col 41}      z{col 49}   P>|z|{col 57}     [95% Con{col 70}f. Interval]
{hline 16}{c +}{hline 11}{hline 11}{hline 9}{hline 8}{hline 13}{hline 12}
_at#immigration {c |}
{space 10} 1 0  {c |}{col 17}{res}{space 2}  3.24665{col 29}{space 2}  .054271{col 40}{space 1}   59.82{col 49}{space 3}0.000{col 57}{space 4}  3.14028{col 70}{space 3} 3.353019
{txt}{space 10} 1 1  {c |}{col 17}{res}{space 2} 7.966705{col 29}{space 2} .4606368{col 40}{space 1}   17.29{col 49}{space 3}0.000{col 57}{space 4} 7.063873{col 70}{space 3} 8.869536
{txt}{space 10} 2 0  {c |}{col 17}{res}{space 2}   3.1823{col 29}{space 2} .0448818{col 40}{space 1}   70.90{col 49}{space 3}0.000{col 57}{space 4} 3.094333{col 70}{space 3} 3.270267
{txt}{space 10} 2 1  {c |}{col 17}{res}{space 2} 6.971054{col 29}{space 2} .3732996{col 40}{space 1}   18.67{col 49}{space 3}0.000{col 57}{space 4}   6.2394{col 70}{space 3} 7.702708
{txt}{space 10} 3 0  {c |}{col 17}{res}{space 2} 3.117951{col 29}{space 2} .0356606{col 40}{space 1}   87.43{col 49}{space 3}0.000{col 57}{space 4} 3.048057{col 70}{space 3} 3.187845
{txt}{space 10} 3 1  {c |}{col 17}{res}{space 2} 5.975403{col 29}{space 2} .2889803{col 40}{space 1}   20.68{col 49}{space 3}0.000{col 57}{space 4} 5.409012{col 70}{space 3} 6.541794
{txt}{space 10} 4 0  {c |}{col 17}{res}{space 2} 3.053602{col 29}{space 2} .0267813{col 40}{space 1}  114.02{col 49}{space 3}0.000{col 57}{space 4} 3.001111{col 70}{space 3} 3.106092
{txt}{space 10} 4 1  {c |}{col 17}{res}{space 2} 4.979752{col 29}{space 2} .2113232{col 40}{space 1}   23.56{col 49}{space 3}0.000{col 57}{space 4} 4.565566{col 70}{space 3} 5.393938
{txt}{space 10} 5 0  {c |}{col 17}{res}{space 2} 2.989253{col 29}{space 2} .0187364{col 40}{space 1}  159.54{col 49}{space 3}0.000{col 57}{space 4}  2.95253{col 70}{space 3} 3.025975
{txt}{space 10} 5 1  {c |}{col 17}{res}{space 2} 3.984101{col 29}{space 2} .1509838{col 40}{space 1}   26.39{col 49}{space 3}0.000{col 57}{space 4} 3.688179{col 70}{space 3} 4.280024
{txt}{space 10} 6 0  {c |}{col 17}{res}{space 2} 2.924903{col 29}{space 2} .0131577{col 40}{space 1}  222.30{col 49}{space 3}0.000{col 57}{space 4} 2.899115{col 70}{space 3} 2.950692
{txt}{space 10} 6 1  {c |}{col 17}{res}{space 2} 2.988451{col 29}{space 2} .1338862{col 40}{space 1}   22.32{col 49}{space 3}0.000{col 57}{space 4} 2.726038{col 70}{space 3} 3.250863
{txt}{space 10} 7 0  {c |}{col 17}{res}{space 2} 2.860554{col 29}{space 2} .0135446{col 40}{space 1}  211.20{col 49}{space 3}0.000{col 57}{space 4} 2.834007{col 70}{space 3} 2.887101
{txt}{space 10} 7 1  {c |}{col 17}{res}{space 2}   1.9928{col 29}{space 2} .1733369{col 40}{space 1}   11.50{col 49}{space 3}0.000{col 57}{space 4} 1.653066{col 70}{space 3} 2.332534
{txt}{space 10} 8 0  {c |}{col 17}{res}{space 2} 2.796205{col 29}{space 2} .0195459{col 40}{space 1}  143.06{col 49}{space 3}0.000{col 57}{space 4} 2.757895{col 70}{space 3} 2.834514
{txt}{space 10} 8 1  {c |}{col 17}{res}{space 2} .9971488{col 29}{space 2} .2432214{col 40}{space 1}    4.10{col 49}{space 3}0.000{col 57}{space 4} .5204438{col 70}{space 3} 1.473854
{txt}{space 10} 9 0  {c |}{col 17}{res}{space 2} 2.731855{col 29}{space 2} .0277289{col 40}{space 1}   98.52{col 49}{space 3}0.000{col 57}{space 4} 2.677508{col 70}{space 3} 2.786203
{txt}{space 10} 9 1  {c |}{col 17}{res}{space 2}  .001498{col 29}{space 2} .3244348{col 40}{space 1}    0.00{col 49}{space 3}0.996{col 57}{space 4}-.6343825{col 70}{space 3} .6373784
{txt}{space 10}10 0  {c |}{col 17}{res}{space 2} 2.667506{col 29}{space 2} .0366605{col 40}{space 1}   72.76{col 49}{space 3}0.000{col 57}{space 4} 2.595653{col 70}{space 3}  2.73936
{txt}{space 10}10 1  {c |}{col 17}{res}{space 2}-.9941529{col 29}{space 2} .4103058{col 40}{space 1}   -2.42{col 49}{space 3}0.015{col 57}{space 4}-1.798337{col 70}{space 3}-.1899683
{txt}{hline 16}{c BT}{hline 11}{hline 11}{hline 9}{hline 8}{hline 13}{hline 12}
{res}
{com}. 
. marginsplot, recastci(rarea)

{text}{p 2 6 2}Variables that uniquely identify margins: ln_house_price immigration{p_end}
{res}
{com}. 
. 
. 
. 
. 
. 
. 
. 
. 
. 
. 
. xtreg foreigner_support i.immigration##i.homeownership ln_income education sex age marriage capital religion ideology, re
{res}
{txt}Random-effects GLS regression                   Number of obs     = {res}     4,404
{txt}Group variable: {res}id                              {txt}Number of groups  = {res}     3,033

{txt}R-sq:                                           Obs per group:
     within  = {res}0.0066                                         {txt}min = {res}         1
{txt}     between = {res}0.0288                                         {txt}avg = {res}       1.5
{txt}     overall = {res}0.0280                                         {txt}max = {res}         2

                                                {txt}Wald chi2({res}11{txt})     =  {res}   117.83
{txt}corr(u_i, X)   = {res}0{txt} (assumed)                    Prob > chi2       =     {res}0.0000

{txt}{hline 26}{c TT}{hline 11}{hline 11}{hline 9}{hline 8}{hline 13}{hline 12}
{col 1}        foreigner_support{col 27}{c |}      Coef.{col 39}   Std. Err.{col 51}      z{col 59}   P>|z|{col 67}     [95% Con{col 80}f. Interval]
{hline 26}{c +}{hline 11}{hline 11}{hline 9}{hline 8}{hline 13}{hline 12}
{space 12}1.immigration {c |}{col 27}{res}{space 2} 1.471831{col 39}{space 2} .2087088{col 50}{space 1}    7.05{col 59}{space 3}0.000{col 67}{space 4}  1.06277{col 80}{space 3} 1.880893
{txt}{space 10}1.homeownership {c |}{col 27}{res}{space 2}-.1869739{col 39}{space 2} .0294077{col 50}{space 1}   -6.36{col 59}{space 3}0.000{col 67}{space 4} -.244612{col 80}{space 3}-.1293358
{txt}{space 25} {c |}
immigration#homeownership {c |}
{space 21}1 1  {c |}{col 27}{res}{space 2}-1.252247{col 39}{space 2} .2744055{col 50}{space 1}   -4.56{col 59}{space 3}0.000{col 67}{space 4}-1.790072{col 80}{space 3}-.7144219
{txt}{space 25} {c |}
{space 16}ln_income {c |}{col 27}{res}{space 2} .0360813{col 39}{space 2} .0240809{col 50}{space 1}    1.50{col 59}{space 3}0.134{col 67}{space 4}-.0111165{col 80}{space 3}  .083279
{txt}{space 16}education {c |}{col 27}{res}{space 2} .0127033{col 39}{space 2} .0163838{col 50}{space 1}    0.78{col 59}{space 3}0.438{col 67}{space 4}-.0194083{col 80}{space 3} .0448149
{txt}{space 22}sex {c |}{col 27}{res}{space 2}-.0476667{col 39}{space 2} .0278646{col 50}{space 1}   -1.71{col 59}{space 3}0.087{col 67}{space 4}-.1022804{col 80}{space 3} .0069469
{txt}{space 22}age {c |}{col 27}{res}{space 2} .0403754{col 39}{space 2} .0128647{col 50}{space 1}    3.14{col 59}{space 3}0.002{col 67}{space 4}  .015161{col 80}{space 3} .0655897
{txt}{space 17}marriage {c |}{col 27}{res}{space 2}-.0436893{col 39}{space 2} .0328974{col 50}{space 1}   -1.33{col 59}{space 3}0.184{col 67}{space 4} -.108167{col 80}{space 3} .0207884
{txt}{space 18}capital {c |}{col 27}{res}{space 2}-.0121752{col 39}{space 2} .0274555{col 50}{space 1}   -0.44{col 59}{space 3}0.657{col 67}{space 4}-.0659869{col 80}{space 3} .0416365
{txt}{space 17}religion {c |}{col 27}{res}{space 2}  .018506{col 39}{space 2} .0267869{col 50}{space 1}    0.69{col 59}{space 3}0.490{col 67}{space 4}-.0339953{col 80}{space 3} .0710074
{txt}{space 17}ideology {c |}{col 27}{res}{space 2}-.0489288{col 39}{space 2} .0144333{col 50}{space 1}   -3.39{col 59}{space 3}0.001{col 67}{space 4}-.0772177{col 80}{space 3}  -.02064
{txt}{space 20}_cons {c |}{col 27}{res}{space 2} 2.497821{col 39}{space 2} .2188449{col 50}{space 1}   11.41{col 59}{space 3}0.000{col 67}{space 4} 2.068892{col 80}{space 3} 2.926749
{txt}{hline 26}{c +}{hline 11}{hline 11}{hline 9}{hline 8}{hline 13}{hline 12}
                  sigma_u {c |} {res} .28909499
                  {txt}sigma_e {c |} {res} .79293418
                      {txt}rho {c |} {res} .11732908{txt}   (fraction of variance due to u_i)
{hline 26}{c BT}{hline 64}

{com}. 
. 
. 
. margins immigration, at(homeownership =(0(1)1))
{res}
{txt}Predictive margins{col 49}Number of obs{col 67}= {res}     4,404
{txt}Model VCE{col 14}: {res}Conventional

{txt}{p2colset 1 14 16 2}{...}
{p2col:Expression}:{space 1}{res:Linear prediction, predict()}{p_end}
{p2colreset}{...}

{txt}{p2colset 1 14 16 2}{...}
{p2col:1._at}:{space 1}{res:{txt:homeownership}{space 3}{txt:=} {space 10}0}{p_end}
{p2colreset}{...}

{txt}{p2colset 1 14 16 2}{...}
{p2col:2._at}:{space 1}{res:{txt:homeownership}{space 3}{txt:=} {space 10}1}{p_end}
{p2colreset}{...}

{res}{txt}{hline 16}{c TT}{hline 11}{hline 11}{hline 9}{hline 8}{hline 13}{hline 12}
{col 17}{c |}{col 29} Delta-method
{col 17}{c |}     Margin{col 29}   Std. Err.{col 41}      z{col 49}   P>|z|{col 57}     [95% Con{col 70}f. Interval]
{hline 16}{c +}{hline 11}{hline 11}{hline 9}{hline 8}{hline 13}{hline 12}
_at#immigration {c |}
{space 11}1 0  {c |}{col 17}{res}{space 2} 2.794615{col 29}{space 2} .0239048{col 40}{space 1}  116.91{col 49}{space 3}0.000{col 57}{space 4} 2.747762{col 70}{space 3} 2.841468
{txt}{space 11}1 1  {c |}{col 17}{res}{space 2} 4.266446{col 29}{space 2}  .207574{col 40}{space 1}   20.55{col 49}{space 3}0.000{col 57}{space 4} 3.859609{col 70}{space 3} 4.673284
{txt}{space 11}2 0  {c |}{col 17}{res}{space 2} 2.607641{col 29}{space 2} .0163436{col 40}{space 1}  159.55{col 49}{space 3}0.000{col 57}{space 4} 2.575608{col 70}{space 3} 2.639674
{txt}{space 11}2 1  {c |}{col 17}{res}{space 2} 2.827226{col 29}{space 2} .1796122{col 40}{space 1}   15.74{col 49}{space 3}0.000{col 57}{space 4} 2.475192{col 70}{space 3} 3.179259
{txt}{hline 16}{c BT}{hline 11}{hline 11}{hline 9}{hline 8}{hline 13}{hline 12}
{res}
{com}. 
. marginsplot

{text}{p 2 6 2}Variables that uniquely identify margins: homeownership immigration{p_end}
{res}
{com}. 
. 
. 
. xtreg foreigner_support i.immigration##c.ln_house_price ln_income education sex age marriage capital religion ideology, re
{res}
{txt}Random-effects GLS regression                   Number of obs     = {res}     4,144
{txt}Group variable: {res}id                              {txt}Number of groups  = {res}     2,885

{txt}R-sq:                                           Obs per group:
     within  = {res}0.0019                                         {txt}min = {res}         1
{txt}     between = {res}0.0271                                         {txt}avg = {res}       1.4
{txt}     overall = {res}0.0246                                         {txt}max = {res}         2

                                                {txt}Wald chi2({res}11{txt})     =  {res}    95.90
{txt}corr(u_i, X)   = {res}0{txt} (assumed)                    Prob > chi2       =     {res}0.0000

{txt}{hline 29}{c TT}{hline 11}{hline 11}{hline 9}{hline 8}{hline 13}{hline 12}
{col 1}           foreigner_support{col 30}{c |}      Coef.{col 42}   Std. Err.{col 54}      z{col 62}   P>|z|{col 70}     [95% Con{col 83}f. Interval]
{hline 29}{c +}{hline 11}{hline 11}{hline 9}{hline 8}{hline 13}{hline 12}
{space 15}1.immigration {c |}{col 30}{res}{space 2} 5.008143{col 42}{space 2} .9055719{col 53}{space 1}    5.53{col 62}{space 3}0.000{col 70}{space 4} 3.233255{col 83}{space 3} 6.783031
{txt}{space 14}ln_house_price {c |}{col 30}{res}{space 2}-.0576577{col 42}{space 2}  .010715{col 53}{space 1}   -5.38{col 62}{space 3}0.000{col 70}{space 4}-.0786587{col 83}{space 3}-.0366568
{txt}{space 28} {c |}
immigration#c.ln_house_price {c |}
{space 26}1  {c |}{col 30}{res}{space 2}-.4951909{col 42}{space 2} .1016598{col 53}{space 1}   -4.87{col 62}{space 3}0.000{col 70}{space 4}-.6944404{col 83}{space 3}-.2959414
{txt}{space 28} {c |}
{space 19}ln_income {c |}{col 30}{res}{space 2} .0578197{col 42}{space 2} .0257555{col 53}{space 1}    2.24{col 62}{space 3}0.025{col 70}{space 4} .0073399{col 83}{space 3} .1082996
{txt}{space 19}education {c |}{col 30}{res}{space 2} .0276269{col 42}{space 2} .0172624{col 53}{space 1}    1.60{col 62}{space 3}0.110{col 70}{space 4}-.0062069{col 83}{space 3} .0614606
{txt}{space 25}sex {c |}{col 30}{res}{space 2}-.0373874{col 42}{space 2} .0287951{col 53}{space 1}   -1.30{col 62}{space 3}0.194{col 70}{space 4}-.0938247{col 83}{space 3}   .01905
{txt}{space 25}age {c |}{col 30}{res}{space 2} .0453245{col 42}{space 2} .0133918{col 53}{space 1}    3.38{col 62}{space 3}0.001{col 70}{space 4} .0190771{col 83}{space 3} .0715718
{txt}{space 20}marriage {c |}{col 30}{res}{space 2}-.0526019{col 42}{space 2} .0343494{col 53}{space 1}   -1.53{col 62}{space 3}0.126{col 70}{space 4}-.1199254{col 83}{space 3} .0147216
{txt}{space 21}capital {c |}{col 30}{res}{space 2} .0175647{col 42}{space 2}  .028435{col 53}{space 1}    0.62{col 62}{space 3}0.537{col 70}{space 4}-.0381669{col 83}{space 3} .0732963
{txt}{space 20}religion {c |}{col 30}{res}{space 2}  .018565{col 42}{space 2} .0276522{col 53}{space 1}    0.67{col 62}{space 3}0.502{col 70}{space 4}-.0356324{col 83}{space 3} .0727624
{txt}{space 20}ideology {c |}{col 30}{res}{space 2}-.0440295{col 42}{space 2} .0149035{col 53}{space 1}   -2.95{col 62}{space 3}0.003{col 70}{space 4}-.0732398{col 83}{space 3}-.0148191
{txt}{space 23}_cons {c |}{col 30}{res}{space 2} 2.629914{col 42}{space 2} .2273664{col 53}{space 1}   11.57{col 62}{space 3}0.000{col 70}{space 4} 2.184284{col 83}{space 3} 3.075543
{txt}{hline 29}{c +}{hline 11}{hline 11}{hline 9}{hline 8}{hline 13}{hline 12}
                     sigma_u {c |} {res} .30119713
                     {txt}sigma_e {c |} {res} .79125815
                         {txt}rho {c |} {res} .12656048{txt}   (fraction of variance due to u_i)
{hline 29}{c BT}{hline 64}

{com}. 
. 
. 
. margins immigration, at(ln_house_price=(4(1)13))
{res}
{txt}Predictive margins{col 49}Number of obs{col 67}= {res}     4,144
{txt}Model VCE{col 14}: {res}Conventional

{txt}{p2colset 1 14 16 2}{...}
{p2col:Expression}:{space 1}{res:Linear prediction, predict()}{p_end}
{p2colreset}{...}

{txt}{p2colset 1 14 16 2}{...}
{p2col:1._at}:{space 1}{res:{txt:ln_house_p~e}{space 4}{txt:=} {space 10}4}{p_end}
{p2colreset}{...}

{txt}{p2colset 1 14 16 2}{...}
{p2col:2._at}:{space 1}{res:{txt:ln_house_p~e}{space 4}{txt:=} {space 10}5}{p_end}
{p2colreset}{...}

{txt}{p2colset 1 14 16 2}{...}
{p2col:3._at}:{space 1}{res:{txt:ln_house_p~e}{space 4}{txt:=} {space 10}6}{p_end}
{p2colreset}{...}

{txt}{p2colset 1 14 16 2}{...}
{p2col:4._at}:{space 1}{res:{txt:ln_house_p~e}{space 4}{txt:=} {space 10}7}{p_end}
{p2colreset}{...}

{txt}{p2colset 1 14 16 2}{...}
{p2col:5._at}:{space 1}{res:{txt:ln_house_p~e}{space 4}{txt:=} {space 10}8}{p_end}
{p2colreset}{...}

{txt}{p2colset 1 14 16 2}{...}
{p2col:6._at}:{space 1}{res:{txt:ln_house_p~e}{space 4}{txt:=} {space 10}9}{p_end}
{p2colreset}{...}

{txt}{p2colset 1 14 16 2}{...}
{p2col:7._at}:{space 1}{res:{txt:ln_house_p~e}{space 4}{txt:=} {space 9}10}{p_end}
{p2colreset}{...}

{txt}{p2colset 1 14 16 2}{...}
{p2col:8._at}:{space 1}{res:{txt:ln_house_p~e}{space 4}{txt:=} {space 9}11}{p_end}
{p2colreset}{...}

{txt}{p2colset 1 14 16 2}{...}
{p2col:9._at}:{space 1}{res:{txt:ln_house_p~e}{space 4}{txt:=} {space 9}12}{p_end}
{p2colreset}{...}

{txt}{p2colset 1 14 16 2}{...}
{p2col:10._at}:{space 1}{res:{txt:ln_house_p~e}{space 4}{txt:=} {space 9}13}{p_end}
{p2colreset}{...}

{res}{txt}{hline 16}{c TT}{hline 11}{hline 11}{hline 9}{hline 8}{hline 13}{hline 12}
{col 17}{c |}{col 29} Delta-method
{col 17}{c |}     Margin{col 29}   Std. Err.{col 41}      z{col 49}   P>|z|{col 57}     [95% Con{col 70}f. Interval]
{hline 16}{c +}{hline 11}{hline 11}{hline 9}{hline 8}{hline 13}{hline 12}
_at#immigration {c |}
{space 10} 1 0  {c |}{col 17}{res}{space 2} 2.970684{col 29}{space 2} .0599303{col 40}{space 1}   49.57{col 49}{space 3}0.000{col 57}{space 4} 2.853223{col 70}{space 3} 3.088145
{txt}{space 10} 1 1  {c |}{col 17}{res}{space 2} 5.998063{col 29}{space 2}  .506517{col 40}{space 1}   11.84{col 49}{space 3}0.000{col 57}{space 4} 5.005308{col 70}{space 3} 6.990818
{txt}{space 10} 2 0  {c |}{col 17}{res}{space 2} 2.913026{col 29}{space 2} .0495614{col 40}{space 1}   58.78{col 49}{space 3}0.000{col 57}{space 4} 2.815888{col 70}{space 3} 3.010165
{txt}{space 10} 2 1  {c |}{col 17}{res}{space 2} 5.445214{col 29}{space 2} .4104945{col 40}{space 1}   13.27{col 49}{space 3}0.000{col 57}{space 4}  4.64066{col 70}{space 3} 6.249769
{txt}{space 10} 3 0  {c |}{col 17}{res}{space 2} 2.855369{col 29}{space 2} .0393783{col 40}{space 1}   72.51{col 49}{space 3}0.000{col 57}{space 4} 2.778189{col 70}{space 3} 2.932549
{txt}{space 10} 3 1  {c |}{col 17}{res}{space 2} 4.892366{col 29}{space 2} .3177936{col 40}{space 1}   15.39{col 49}{space 3}0.000{col 57}{space 4} 4.269502{col 70}{space 3}  5.51523
{txt}{space 10} 4 0  {c |}{col 17}{res}{space 2} 2.797711{col 29}{space 2} .0295733{col 40}{space 1}   94.60{col 49}{space 3}0.000{col 57}{space 4} 2.739748{col 70}{space 3} 2.855674
{txt}{space 10} 4 1  {c |}{col 17}{res}{space 2} 4.339517{col 29}{space 2} .2324233{col 40}{space 1}   18.67{col 49}{space 3}0.000{col 57}{space 4} 3.883976{col 70}{space 3} 4.795059
{txt}{space 10} 5 0  {c |}{col 17}{res}{space 2} 2.740053{col 29}{space 2} .0206915{col 40}{space 1}  132.42{col 49}{space 3}0.000{col 57}{space 4} 2.699499{col 70}{space 3} 2.780608
{txt}{space 10} 5 1  {c |}{col 17}{res}{space 2} 3.786669{col 29}{space 2} .1661001{col 40}{space 1}   22.80{col 49}{space 3}0.000{col 57}{space 4} 3.461118{col 70}{space 3} 4.112219
{txt}{space 10} 6 0  {c |}{col 17}{res}{space 2} 2.682395{col 29}{space 2} .0145366{col 40}{space 1}  184.53{col 49}{space 3}0.000{col 57}{space 4} 2.653904{col 70}{space 3} 2.710887
{txt}{space 10} 6 1  {c |}{col 17}{res}{space 2}  3.23382{col 29}{space 2} .1473047{col 40}{space 1}   21.95{col 49}{space 3}0.000{col 57}{space 4} 2.945108{col 70}{space 3} 3.522532
{txt}{space 10} 7 0  {c |}{col 17}{res}{space 2} 2.624738{col 29}{space 2} .0149703{col 40}{space 1}  175.33{col 49}{space 3}0.000{col 57}{space 4} 2.595397{col 70}{space 3} 2.654079
{txt}{space 10} 7 1  {c |}{col 17}{res}{space 2} 2.680971{col 29}{space 2} .1906539{col 40}{space 1}   14.06{col 49}{space 3}0.000{col 57}{space 4} 2.307296{col 70}{space 3} 3.054646
{txt}{space 10} 8 0  {c |}{col 17}{res}{space 2}  2.56708{col 29}{space 2} .0215992{col 40}{space 1}  118.85{col 49}{space 3}0.000{col 57}{space 4} 2.524746{col 70}{space 3} 2.609414
{txt}{space 10} 8 1  {c |}{col 17}{res}{space 2} 2.128123{col 29}{space 2} .2674696{col 40}{space 1}    7.96{col 49}{space 3}0.000{col 57}{space 4} 1.603892{col 70}{space 3} 2.652353
{txt}{space 10} 9 0  {c |}{col 17}{res}{space 2} 2.509422{col 29}{space 2}  .030636{col 40}{space 1}   81.91{col 49}{space 3}0.000{col 57}{space 4} 2.449377{col 70}{space 3} 2.569468
{txt}{space 10} 9 1  {c |}{col 17}{res}{space 2} 1.575274{col 29}{space 2} .3567518{col 40}{space 1}    4.42{col 49}{space 3}0.000{col 57}{space 4} .8760535{col 70}{space 3} 2.274495
{txt}{space 10}10 0  {c |}{col 17}{res}{space 2} 2.451765{col 29}{space 2} .0404997{col 40}{space 1}   60.54{col 49}{space 3}0.000{col 57}{space 4} 2.372387{col 70}{space 3} 2.531143
{txt}{space 10}10 1  {c |}{col 17}{res}{space 2} 1.022425{col 29}{space 2}  .451159{col 40}{space 1}    2.27{col 49}{space 3}0.023{col 57}{space 4}   .13817{col 70}{space 3} 1.906681
{txt}{hline 16}{c BT}{hline 11}{hline 11}{hline 9}{hline 8}{hline 13}{hline 12}
{res}
{com}. 
. marginsplot, recastci(rarea)

{text}{p 2 6 2}Variables that uniquely identify margins: ln_house_price immigration{p_end}
{res}
{com}. interflex foreigner_right immigration homeownership ln_income education sex age marriage capital religion ideology, ylab(Foreigner Right) dlab(Immigration) xlab(Homeownership)
{txt}p value of Wald test: {res}    .

{com}. 
. 
. 
. interflex foreigner_right immigration ln_house_price ln_income education sex age marriage capital religion ideology, ylab(Foreigner Right) dlab(Immigration) xlab(ln House Price)
{txt}p value of Wald test: {res}0.0000

{com}. 
. 
. 
. 
. 
. 
. 
. interflex foreigner_support immigration homeownership ln_income education sex age marriage capital religion ideology, ylab(Financial Support) dlab(Immigration) xlab(Homeownership)
{txt}p value of Wald test: {res}    .

{com}. 
. 
. 
. interflex foreigner_support immigration ln_house_price ln_income education sex age marriage capital religion ideology, ylab(Financial Support) dlab(Immigration) xlab(ln House Price)
{txt}p value of Wald test: {res}0.0715

{com}. log close
      {txt}name:  {res}<unnamed>
       {txt}log:  {res}C:\research\works\주제40_집_이민자_외국인지원\data\code.smcl
  {txt}log type:  {res}smcl
 {txt}closed on:  {res} 3 May 2025, 21:49:53
{txt}{.-}
{smcl}
{txt}{sf}{ul off}